package com.lbi.mvc.model {	import flash.events.Event;	import flash.events.EventDispatcher;	import com.lbi.animation.group.Queue;	/**	 * @author michaelforrest	 */	public class SequentialDependencyLoader extends EventDispatcher {		public static var READY : String = "ready";		public function dispatchReady():void {dispatchEvent(new Event(READY));		}		public function SequentialDependencyLoader(dependencies : Array) {			var queue : Queue = new Queue();			for (var i : Number = 0;i < dependencies.length; i++) {				var d : EventDispatcher = dependencies[i];				queue.addMethod(d, null, Event.COMPLETE);			}			queue.addEventListener(Event.COMPLETE, onReady);			queue.go();		}		private function onReady(event : Event) : void {			dispatchReady();		}	}}